package com.longfor.dragonshard.controller;

import com.longfor.dragonshard.dto.log.LogSearchListDTO;
import com.longfor.dragonshard.service.ILogService;
import com.longfor.drogon.common.bean.LFDatatableResultBean;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author wangyong
 * @version v1.0
 * @create 2018-01-25 22:15
 **/
@CrossOrigin
@RestController
public class LogController {
    private Logger logger = LoggerFactory.getLogger(LogController.class);

    @Autowired
    private ILogService logService;

    @PostMapping(value = "/admin/api/log/list")
    public LFDatatableResultBean list(@RequestBody LogSearchListDTO logSearchListDTO)
            throws IllegalAccessException {
    	System.out.println("======AAAAAAAAA=====");
        return logService.searchList(logSearchListDTO);
    }
}
